class StringRevert {

    public static String revert(String str) {
        StringBuilder sb = new StringBuilder();
        for (int i = str.length() - 1;i>=0;i--) {
            sb.append(str.charAt(i));
        }
        return sb.toString();
    }

    public static void main(String args[]) {
        String str = "azmohan";
        System.out.println(revert(str));

    }
}
